// 如何制作一架一模一样的飞机
var Plane = function() {
    this.blood =100;
    this.attackLevel =100;
    this.defenseLevel =100;
}

var plane = new Plane();

var plane = new Plane();
plane.blood =500;
plane.attackLevel =500;
plane.defenseLevel =500;

var clonePlane = Object.create(plane);
console.log(clonePlane.attackLevel);

// 用原型链改写OBJECT.CREATE方法,比该方法更快
var createObj = function (obj) {
    var F = function(){};
    F.prototype = obj;
    return new F();
};

var clonePlane = (plane);
console.log(clonePlane.defenseLevel);


// 基于原型链的委托机制就是原型继承的本质。